import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { RepairBugsComponent } from './repairBugs/repairBugs';
import { UnRepairBugsComponent } from './unRepairBugs/unRepairBugs';

const routes: Routes = [
	{
		path: '',
		children: [
			{
				path: '',
				redirectTo: 'repairBugs',
			},
			{
				path: 'repairBugs',
				component: RepairBugsComponent,
				data: {
					title: '已修复漏洞',
					url: 'bugsMgmt/repairBugs',
				},
			},
			{
				path: 'unRepairBugs',
				component: UnRepairBugsComponent,
				data: {
					title: '未修复漏洞',
					url: 'bugsMgmt/unRepairBugs',
				},
			},
		],
	},
];

@NgModule({
	imports: [RouterModule.forChild(routes)],
	exports: [RouterModule],
})
export class BugsMgmtRoutingModule {}
